package com.molichuxing.gateway.bff.order.services;

import com.molichuxing.framework.dto.Paged;
import com.molichuxing.framework.service.RootService;
import com.molichuxing.gateway.bff.order.entity.request.create.OrderRecycleCarsCreateVo;
import com.molichuxing.gateway.bff.order.entity.request.create.OrderRenegeCreateVo;
import com.molichuxing.gateway.bff.order.entity.request.modify.OrderRenegeCancelModifyVo;
import com.molichuxing.gateway.bff.order.entity.request.modify.OrderRenegeCompleteModifyVo;
import com.molichuxing.gateway.bff.order.entity.request.modify.OrderRenegeCostModifyVo;
import com.molichuxing.gateway.bff.order.entity.response.OrderNegotiateRenegeVo;
import com.molichuxing.gateway.bff.order.entity.response.OrderRenegeVo;

import java.util.Map;

/**
 * 订单相关bff
 *
 * @author zhaopenghui
 * @date 2020年3月3日
 */
public interface OrderRenegeBffService extends RootService {

    /**
     * 同意退租
     *
     * @param orderRenegeCreateVo
     * @return
     * @throws Exception
     */
    Boolean createRenege(OrderRenegeCreateVo orderRenegeCreateVo) throws Exception;


    /**
     * 取消退租
     *
     * @param orderRenegeCancelModifyVo
     * @return
     * @throws Exception
     */
    Boolean modifyCancel(OrderRenegeCancelModifyVo orderRenegeCancelModifyVo) throws Exception;

    /**
     * 发起收/付款
     *
     * @param orderRenegeCostModifyVo
     * @return
     * @throws Exception
     */
    Boolean modifyCost(OrderRenegeCostModifyVo orderRenegeCostModifyVo) throws Exception;

    /**
     * 退款完成
     *
     * @param orderRenegeCompleteModifyVo
     * @return
     * @throws Exception
     */
    Boolean modifyComplete(OrderRenegeCompleteModifyVo orderRenegeCompleteModifyVo) throws Exception;


    /**
     * 查询退租信息
     *
     * @param orderCode
     * @param userId
     * @return
     */
    OrderRenegeVo getOrderRenege(Long orderCode, Integer userId);

    /**
     * 查询订单协商退租列表
     *
     * @param selectParams
     * @param pageNum
     * @param pageSize
     * @return
     */
    Paged<OrderNegotiateRenegeVo> getNegotiateRenegeList(Map<String, Object> selectParams,
                                                         Integer pageNum, Integer pageSize) throws Exception;

    /**
     * 确认收车
     *
     * @param createVo
     * @return
     */
    boolean createRecycleCars(OrderRecycleCarsCreateVo createVo) throws Exception;

    /**
     * 退租订单退租完成
     *
     * @param modifyVo
     * @return
     */
    boolean modifyRenegeFinish(OrderRenegeCompleteModifyVo modifyVo);
}
